import request from "@/Http/request"


//获取角色
export const GetRole=async(data:any)=>{
    return request({
        url:"/api/Role/GetRole",
        method:"get",
        params:data
    });
};


//删除角色
export const DeleteRole=async(data:any)=>{
    return request({
        url:"/api/Role/DeleteRole?RoleId="+data,
        method:"delete",
    });
};


//设置角色状态
export const UpdateRoleStatus=async(data:any)=>{
    return request({
        url:"/api/Role/UpdateRoleState",
        method:"put",
        params:data
    });
};

//编辑职务
export const UpdateRoleZhiW=async(data:any)=>{
    return request({
        url:"/api/Role/UpdateRole",
        method:"put",
        params:data
    });
};

//新建职务
export const AddRoleZhiW=async(data:any)=>{
    return request({
        url:"/api/Role/AddRole",
        method:"post",
        data
    });
};